Keycloak REST Services 1.5.0-Final

Path: / admin / realms / {realm} / clients / {id} / scope-mappings / clients / {client}

Get the roles associated with a client's scope for a specific client.

Path parameters:
realm - realm name (not id!)
id - id of client (not client-id)
client -

Sub-Resources
Resources
NameDescription
availableThe available client-level roles that can be associated with the client's scope
compositeGet effective client roles that are associated with the client's scope for a specific client.

Resource Methods
Method Summary
NameDescription
GET /admin/realms/{realm}/clients/{id}/scope-mappings/clients/{client}Get the roles associated with a client's scope for a specific client.
POST /admin/realms/{realm}/clients/{id}/scope-mappings/clients/{client}Add client-level roles to the client's scope
DELETE /admin/realms/{realm}/clients/{id}/scope-mappings/clients/{client}Remove client-level roles from the client's scope.

Method Detail

GET /admin/realms/{realm}/clients/{id}/scope-mappings/clients/{client}

Get the roles associated with a client's scope for a specific client.

HTTP Example:
GET /admin/realms/{realm}/clients/{id}/scope-mappings/clients/{client}
API Example:

ScopeMappedClientResource.getClientScopeMappings({'realm': /* name realm name (not id!) */,
  'id': /* id id of client (not client-id) */,
  'client': …});

Output:
List<RoleRepresentation> -
Produces:
application/json

POST /admin/realms/{realm}/clients/{id}/scope-mappings/clients/{client}

Add client-level roles to the client's scope

HTTP Example:
POST /admin/realms/{realm}/clients/{id}/scope-mappings/clients/{client}
API Example:

ScopeMappedClientResource.addClientScopeMapping({'realm': /* name realm name (not id!) */,
  'id': /* id id of client (not client-id) */,
  'client': …,
  '$entity': /* roles */});

Input:
List<RoleRepresentation>
Output:
void
Consumes:
application/json

DELETE /admin/realms/{realm}/clients/{id}/scope-mappings/clients/{client}

Remove client-level roles from the client's scope.

HTTP Example:
DELETE /admin/realms/{realm}/clients/{id}/scope-mappings/clients/{client}
API Example:

ScopeMappedClientResource.deleteClientScopeMapping({'realm': /* name realm name (not id!) */,
  'id': /* id id of client (not client-id) */,
  'client': …,
  '$entity': /* roles */});

Input:
List<RoleRepresentation>
Output:
void
Consumes:
application/json

Keycloak REST Services 1.5.0-Final